package com.regis.comment;

import lombok.Getter;

/**
 * @author 计算机系 ITAEM 纱雾休比我老婆
 * @Description 自定义异常类
 * @date 2022/5/15 19:24
 */
@Getter
public class GlobalException extends RuntimeException{

    private CodeMsg codeMsg;

    public GlobalException(CodeMsg codeMsg){
        super(codeMsg.toString());
        this.codeMsg = codeMsg;
    }


    public CodeMsg getCodeMsg(){
        return codeMsg;
    }
}
